Use an absolute path for CompileShaders.cmd - #660
Open
bghgary wants to merge 1 commit into
Open
Conversation
The shader build step names the script as a bare CompileShaders.cmd, which only resolves because Windows falls back to searching the current directory when looking up an executable. That fallback is disabled whenever NoDefaultCurrentDirectoryInExePath is present in the environment, and the build then fails with "no such file or directory". WORKING_DIRECTORY already points at Src/Shaders, so naming the script by absolute path keeps the same intent without relying on current-directory lookup. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 714b4495-258e-4645-abf7-26c17bc29d5b
|
Azure Pipelines: There may be pipelines that require an authorized user to comment /azp run to run. |
Collaborator
|
You could make the same change in two places for DirectXTex if you want: https://github.com/microsoft/DirectXTex/ as well as DirectX Tool Kit for DX12: |
walbourn
approved these changes
Aug 1, 2026
This was referenced Aug 3, 2026
Author
|
[Responded by Copilot on behalf of @bghgary]
Done: microsoft/DirectXTex#730 and microsoft/DirectXTK12#431. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[Created by Copilot on behalf of @bghgary]
The shader build step names the script as a bare
CompileShaders.cmd, which only resolves because Windows falls back to searching the current directory when looking up an executable. That fallback is disabled wheneverNoDefaultCurrentDirectoryInExePathis present in the environment — its presence alone is enough, the value is irrelevant — so any hardened build or automation environment fails withGenerating HLSL shaders...followed byno such file or directory.WORKING_DIRECTORYalready points atSrc/Shaders, so naming the script by absolute path keeps the same intent without relying on current-directory lookup.Verified on Windows with the
Visual Studio 17 2022generator, building theDirectXTKtarget:no such file or directoryThe shader step regenerated the
.incfiles in each passing case.